import React from 'react';
import { IRoute } from '../types/route';

const Login = React.lazy(() => import('../pages/system/login'));

const routes: IRoute[] = [
  {
    path: '/login',
    name: 'Login',
    component: Login,
    meta: {
      title: '登录',
    },
  },
  {
    path: '/',
    name: 'Root',
    redirect: '/dashboard',
    meta: {
      title: '系统',
    },
    children: [
      {
        path: '/dashboard',
        name: 'Dashboard',
        meta: {
          title: '首页',
          icon: 'dashborad',
        },
      },
    ],
  },
];

export default routes;
